package com.westos.mvc;

import com.westos.calcv2.IOperator;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Component;
import org.springframework.stereotype.Service;

@Service
public class UserService {

    @Autowired
    private IOperator iOperator;

    public IOperator getiOperator() {
        return iOperator;
    }

    public void setiOperator(IOperator iOperator) {
        this.iOperator = iOperator;
    }

    public Integer removeUser(){
        if(iOperator==null){
            System.out.println("iOperator未正确装配");
        }else{
            System.out.println("userdao已经正确装配");
        }
        System.out.println("删除用户");
        return iOperator.operator(1,2);
    }
}